/*
 * =====================================================================================
 *
 *       Filename:  config.hpp
 *
 *    Description:  
 *
 *        Version:  1.0
 *        Created:  23.08.2012 10:49:50
 *       Revision:  none
 *       Compiler:  gcc
 *
 *         Author:  akoww (), 
 *   Organization:  
 *
 * =====================================================================================
 */

#ifndef CONFIG_HPP_
#define CONFIG_HPP_

#include <functional>
#include <iostream>
#include <fstream>
#include <string>

#include "drosera.pb.hpp"
#include "globals.hpp"

namespace Drosera {

struct config_t {
	std::string path;
	std::string host;
	std::string prv;
	std::string pub;
	unsigned int port;
};

class Config {

	public:
		Config ( void );
		~Config ( void );
		unsigned int getPort ( void );
		const std::string& getHost ( void );
		const std::string& getCertPub ( void );
		const std::string& getCertPrv ( void );
		bool readConfig ( const char* );
		static bool createConfig ( config_t& );
		static bool checkExist ( const char* );

	protected:

	private:
		static Drosera::Configuration m_config;

};

}


#endif
